The characteristics of a tween are specified by the atoms in a tween QT atom container. For information about QT atom containers, see "QuickTime Atoms" (page 47) .
A tween QT atom container can contain the following atoms:
Specifies a tween, which can be either a single tween, a tween in a tween sequence, or an interpolation tween.
Its parent is the tween QT atom container (which you specify with the constant kParentAtomIsContainer ).
The index of a kTweenEntry atom specifies when it was added to the QT atom containe r ; the first added has the index 1 , the second 2 , and so on. The ID of a kTweenEntry atom can be any ID that is unique among the kTweenEntry atoms contained in the same QuickTime atom container.
This atom is a parent atom. It must contain the following child atoms:
A kTweenEntry atom can contain any of the following optional child atoms:
If this atom specifies a path tween, it can contain the following optional child atom:
If a kTweenEntry atom specifies an interpolation tween, it must contain the following child atom(s):
If this atom specifies an interpolation tween, it can contain either of the following optional child atoms:
For a tween in a tween track of a QuickTime movie, specifies a time offset from the start of the tween media sample to the start of the tween. The time units are the units used for the tween track.
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only one kTweenStartOffset atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. The data type of its data is TimeValue .
This atom is optional. If it is not included, the tween operation begins at the start of the tween media sample.
Specifies the duration of a tween operation. When a QuickTime movie includes a tween track, the time units for the duration are those of the tween track. If a tween component is used outside of a movie, the application using the tween data determines how the duration value and values returned by the component are interpreted.
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only one kTweenDuration atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. The data type of its data is TimeValue .
This atom is optional. If it is not included, the duration of the tween is the duration of the media sample that contains it.
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain any number of kTweenData atoms. Each kTweenData atom can contain different data to be processed by the tween component, and a tween component can process data from only one kTweenData atom a time. For example, an application can use a list tween to animate sprites. The kTweenEntry atom for the tween could contain three sets of animation data, one for moving the sprite from left to right, one for moving the sprite from right to left, and one for moving the sprite from top to bottom. In this case, the kTweenEntry atom for the tween would contain three kTweenData atoms, one for each data set. The application would specify the desired data set by specifying the ID of the kTweenData atom to use.
The index of a kTweenData atom specifies when it was added to the kTweenEntry atom; the first added has the index 1 , the second 2 , and so on. The ID of a kTweenData atom can be any ID that is unique among the kTweenData atoms contained in the same kTweenEntry atom.
At least one kTweenData atom is required in a kTweenEntry atom.
For single tweens, a kTweenData atom is a leaf atom. It can contain data of any type.
For polygon tweens, a kTweenData atom is a leaf atom. The data type of its data is Fixed[27] , which specifies three polygons as described in "Using Path Tween Components" .
For path tweens, a kTweenData atom is a leaf atom. The data type of its data is Handle , which contains a QuickTime vector as described in "Using Path Tween Components" .
In interpolation tweens, a kTweenData atom is a leaf atom. It can contain data of any type. An interpolation tween can be any tween other than a list tween that returns a time value, as described in "Interpolation Tweens" .
In list tweens, a kTweenData atom is a parent atom that must contain the following child atoms:
Specifies the name of a tween. The name, which is optional, is not used by tween components, but it can be used by applications or other software.
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only one kNameAtom atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. Its data type is StringPtr .
This atom is optional. If it is not included, the tween does not have name.
Specifies the tween type (the data type of the data for the tween operation).
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only one kTweenType atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. The data type of its data is OSType .
Contains flags that control the tween operation. One flag that controls path tweens is defined:
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only one kTweenFlags atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. The data type of its data is Long .
This atom is optional. If it is not included, no flags are set.
Specifies an initial angle of rotation for a path tween of type kTweenTypePathToMatrixRotation , kTweenTypePathToMatrixTranslation , or kTweenTypePathToMatrixTranslationAndRotation .
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only one kInitialRotationAtom atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. Its data type is Fixed .
This atom is optional. If it is not included, no initial rotation of the tween is performed.
Specifies the atom type of the elements in a list tween.
Its parent atom is a kTweenData atom.
A kTweenEntry atom can contain only one kListElementType atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. Its data type is QTAtomType .
This atom is required in the kTweenData atom for a list tween.
Specifies an initial transform for a 3D tween whose tween type is one of the following: kTweenType3dCameraData, kTweenType3dMatrix, kTweenType3dQuaternion, kTweenType3dRotate, kTweenType3dRotateAboutAxis, kTweenType3dRotateAboutAxis, kTweenType3dRotateAboutPoint, kTweenType3dRotateAboutVector, kTweenType3dScale, or kTweenType3dTranslate.
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only one kTween3dInitialCondition atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. The data type of its data is as follows:
This atom is optional. For each tween type, the default value is the data structure that specifies an identity transform, that is, a transform that does not alter the 3D data.
Specifies the maximum output value of an interpolation tween. If a kTweenOutputMax atom is included for an interpolation tween, output values for the tween are scaled to be within the minimum and maximum values. The minimum value is either the value of the kTweenOutputMin atom or, if there is no kTweenOutputMin atom, 0 . For example, if an interpolation tween has values between 0 and 4, and it has kTweenOutputMin and kTweenOutputMax atoms with values 1 and 2, respectively, a value of 0 (the minimum value before scaling) is scaled to 1 (the minimum specified by the kTweenOutputMin atom), a value of 4 (the maximum value before scaling) is scaled to 2 (the maximum specified by the kTweenOutputMax atom), and a value of 3 (three-quarters of the way between the maximum and minimum values before scaling) is scaled to 1.75 (three-quarters of the way between the values of the kTweenOutputMin and kTweenOutputMax atoms).
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only on e kTweenOutputMax atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. The data type of its data is Fixed .
This atom is optional. If it is not included, QuickTime does not scale interpolation tween values.
Specifies the minimum output value of an interpolation tween. If both kTweenOutputMin and kTweenOutputMax atoms are included for an interpolation tween, output values for the tween are scaled to be within the minimum and maximum values. For example, if an interpolation tween has values between 0 and 4, and it has kTweenOutputMin and kTweenOutputMax atoms with values 1 and 2, respectively, a value of 0 (the minimum value before scaling) is scaled to 1 (the minimum specified by the kTweenOutputMin atom), a value of 4 (the maximum value before scaling) is scaled to 2 (the maximum specified by the kTweenOutputMax atom), and a value of 3 (three-quarters of the way between the maximum and minimum values before scaling) is scaled to 1.75 (three-quarters of the way between the values of the kTweenOutputMin and kTweenOutputMax atoms).
If a kTweenOutputMin atom is included but a kTweenOutputMax atom is not, QuickTime does not scale interpolation tween values.
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only on e kTweenOutputMin atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. The data type of its data is Fixed .
This atom is optional. If it is not included but a kTweenOutputMax atom is, the tween component uses 0 as the minimum value for scaling values of an interpolation tween.
Specifies an interpolation tween to use for a specified kTweenData atom. There can be any number of kTweenInterpolationID atoms for a tween, one for each kTweenData atom to be interpolated.
Its parent atom is a kTweenEntry atom.
The index of a kTweenInterpolationID atom specifies when it was added to the kTweenEntry atom; the first added has the index 1 , the second 2 , and so on. The ID of a kTweenInterpolationID atom must (1) match the atom ID of the kTweenData atom to be interpolated, and (2) be unique among the kTweenInterpolationID atoms contained in the same kTweenEntry atom.
This atom is a leaf atom. The data type of its data is QTAtomID .
Contains the data for a QuickDraw picture. Used only by a kTweenTypeQDRegion tween, as described in "Tween Components for QuickDraw 3D" .
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only on e kTweenPictureData or kTweenRegionData atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. The data type of its data is Picture .
Either a kTweenPictureData or kTweenRegionData atom is required for a kTweenTypeQDRegion tween.
Contains the data for a QuickDraw region. Used only by a kTweenTypeQDRegion tween, as described in "Tween Components for QuickDraw 3D" .
Its parent atom is a kTweenEntry atom.
A kTweenEntry atom can contain only on e kTweenRegionData or kTweenPictureData atom. The ID of this atom is always 1 . The index of this atom is always 1 .
This atom is a leaf atom. The data type of its data is Region .
Either a kTweenPictureData or kTweenRegionData atom is required for a kTweenTypeQDRegion tween.
Specifies an entry in a tween sequence.
Its parent is the tween QT atom container (which you specify with the constant kParentAtomIsContainer ).
The ID of a kTweenSequenceElement atom must be unique among the kTweenSequenceElement atoms in the same QT atom container. The index of a kTweenSequenceElement atom specifies its order in the sequence; the first entry in the sequence has the index 1 , the second 2 , and so on.
This atom is a leaf atom. The data type of its data is TweenSequenceEntryRecord , a data structure that contains the following fields:
| Previous | Chapter Contents | Chapter Top | Next |